1. Field of the Invention
The present invention relates to data processing systems, and in particular to migration of data between physical pages that are subject to access by input/output (I/O) devices. More particularly, the present invention relates to temporarily stalling selected Direct Memory Access (DMA) operations in a physical I/O adapter in order to permit migration of data between physical pages that are subject to access by the physical I/O adapter.
2. Description of the Related Art
A computer system may be reconfigured while running without disrupting data processing in the system. For example, with multiple operating systems running on the computer, one of the operating systems may be using a certain block of memory, and there may be a need to reallocate that block of memory for use by a second operating system. Thus, the first operating system must stop using the block of physical memory to allow the second operation system access. As another example, a problem may be detected in a block of physical memory, in which case it may be desirable to remove the memory from operation so that it can be replaced. Thus, the data within a particular physical page may need to be moved or use of the physical page may need to be blocked for a period of time. If this block of memory is subject to access by I/O devices the problem of migrating or blocking the use of the physical page becomes difficult.
One method for migrating data that is subject to access by an I/O device is to temporarily but completely disable all arbitration that is done by the I/O adapter to which the I/O device is coupled in order to access the particular physical page. The process of arbitration is the first step taken during a DMA process. When arbitration is disabled, all DMA operations of the physical I/O adapter are disabled. Thus, for a short time period, all DMA operations for the physical I/O adapter that needs to access the data that is to be migrated are totally disabled when arbitration is disabled. During the short time period, the physical page data is then either migrated or updated. Once the migration or update of the physical page is complete, the DMA operations are once again enabled in the I/O adapter.
However, although existing adapters, such as industry standard Peripheral Component Interconnect (PCI) Express bus, allow for temporarily disabling or stalling DMA operations to perform data migration, these adapters require that all of the DMA operations be temporarily suspended. A drawback to this current approach is that disabling all DMA operations on the bus may adversely affect other in-flight DMA transfers to/from the I/O adapter, and cause the physical I/O adapter to enter an error state.
Therefore, it would be advantageous to have a mechanism for stalling only selected DMA operations in a physical I/O adapter in order to permit migration of physical pages that are subject to access by the physical I/O adapter while allowing other DMA operations from the physical I/O adapter to other pages in system memory to continue.